package com.numbfish.ch04_ex32_mybatis_plus_mysql.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableLogic;
import lombok.Data;

import java.time.LocalDateTime;

@Data
public class SysUser {
    private Long id;
    private String name;
    private Integer age;
    private String email;
    private String version;
    // 1 标识删除 0 标识未删除
    //@TableLogic(value = "0", delval = "1")
    // 查询时不显示
    @TableLogic
    //@TableField(select = false)
    private Integer deleted;



    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @TableField(fill = FieldFill.UPDATE)
    private LocalDateTime updateTime;
}
